#pragma once

#include "../../../../include/singleton.h"
#include "../../../../include/log_interface.hpp"

class CLogMgr
{
    DECLARE_SINGLETON(CLogMgr)
public:
    CLogMgr(void);
    ~CLogMgr(void);

    bool Init(void);
    void UnInit(void);

    inline IFileLog& get_file_log(void){return *m_file_log;}

protected:
    IFileLog*   m_file_log;
};

#define LOG_CRI CLogMgr::Instance()->get_file_log().LogCri
#define LOG_WRN CLogMgr::Instance()->get_file_log().LogWrn
#define LOG_INF CLogMgr::Instance()->get_file_log().LogInf
#define LOG_DBG CLogMgr::Instance()->get_file_log().LogDbg